Pulmonary arterial hypertension algorithm